<?php /* Smarty version Smarty-3.1.18, created on 2015-12-21 17:59:16
         compiled from "/Applications/MAMP/htdocs/ccgift/cc/Mobile/View/default/Index/index.html" */ ?>
<?php /*%%SmartyHeaderCode:20758950865677b040774211-42761958%%*/if(!defined('SMARTY_DIR')) exit('no direct access allowed');
$_valid = $_smarty_tpl->decodeProperties(array (
  'file_dependency' => 
  array (
    'a9de58430bfafaf8fd3238550fb6e1958ff6ed90' => 
    array (
      0 => '/Applications/MAMP/htdocs/ccgift/cc/Mobile/View/default/Index/index.html',
      1 => 1450691954,
      2 => 'file',
    ),
  ),
  'nocache_hash' => '20758950865677b040774211-42761958',
  'function' => 
  array (
  ),
  'version' => 'Smarty-3.1.18',
  'unifunc' => 'content_5677b040829e29_87930346',
  'variables' => 
  array (
    '_C' => 0,
    'canplay' => 0,
    'score' => 0,
    'se' => 0,
    'type' => 0,
    'jsdk' => 0,
    'shareInfo' => 0,
    'config' => 0,
  ),
  'has_nocache_code' => false,
),false); /*/%%SmartyHeaderCode%%*/?>
<?php if ($_valid && !is_callable('content_5677b040829e29_87930346')) {function content_5677b040829e29_87930346($_smarty_tpl) {?><!DOCTYPE html>
<html lang="zh-cn">
<head>
	<meta charset="utf-8">
	<meta http-equiv="X-UA-Compatible" content="IE=edge">
	<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1.0, user-scalable=no">
	<meta name="description" content="">
	<meta name="author" content="">
	<title>长城圣诞庆</title>
	<link rel="stylesheet" type="text/css" href="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
css/main.css">

</head>
<body>
	<!-- logo -->
	<div class="logo" id="logo">
		<img src="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
images/logo.png" alt="">
	</div>
	<!-- 返回首页 -->
	<div class="page back" id="back" onclick="myback();">
		<img src="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
images/back.png">
	</div>
	<!-- loading -->
	<div class="load" id="loading">
		<div class="load_box">
			<img src="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
images/load_box.png" style="width:100%;" alt="">
			<img src="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
images/load_block.png" class="load_block" id="aaa" alt="">
		</div>
	</div>
	<!-- index -->
	<div class="page index" id="index_page">
		<div class="index-sd"></div>
		<div class="index-bottom">
			<img src="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
images/index-infobg.png" alt="">
			<div class="index-btn">
				<p><input type="button" class="btn red-btn" value="活动规则" onclick="show_rule()"><input type="button" class="btn red-btn <?php if ($_smarty_tpl->tpl_vars['canplay']->value['status']==1) {?>gameStart<?php } else { ?>gameTip<?php }?>" data-msg="<?php echo $_smarty_tpl->tpl_vars['canplay']->value['msg'];?>
" value="开始游戏"></p>
				<p><input type="button" class="btn white-btn" onclick="show_gift()" value="活动奖品"><input type="button" class="btn white-btn" value="积分榜" onclick="show_jifen()"><input type="button" class="btn white-btn" value="邀请好友" onclick="myshare()"></p>
			</div>
		</div>
	</div>
	<!-- 奖品 -->
	<div class="page gift" id="gift">
		<img src="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
images/gf1.png" alt="">
		<img src="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
images/gf2.png" alt="">
		<img src="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
images/gf3.png" alt="">
		<img src="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
images/gf4.png" alt="">
		<img class="bottom" src="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
images/bottom.png" alt="">
	</div>
	<!-- 规则 -->
	<div class="page rule" id="rule">
		<img src="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
images/rule-title.png" alt="">
		<div class="rule-item">
			<p>活动时间</p>
			<p>2015年12月24号</p>
			<p>——2015年12月28号</p>
		</div>
		<div class="rule-item">
			<p>活动规则</p>
			<p>每个用户只有五次参与活动机会。游戏开始后，30秒内限时滑动圣诞老人加分。圣诞老人接到长城天玺一体机+50分、PC电源+20分、移动3C电源+10分、炸弹-10分；</p>
			<p>用户可将游戏分享给好友，邀请朋友帮忙玩游戏可加分，每位好友仅可加分1次，最多可邀请30位好友；每分享一位好友可以同时增加双方的积分，分享越多积分也越多。</p>
		</div>
		<div class="rule-item">
			<p>活动奖品</p>
			<p>28号23点59分游戏将结束并关闭，根据玩家总积分榜排名靠前依次设置一二三等奖和纪念奖；获奖者名单将在活动结束后7天内公布。</p>
			<p>一等奖：总积分第一名，奖品为长城天   玺一体机一台；</p>
			<p>二等奖：总积分第2-10名，奖品为长城3C安全移动电源一个；</p>
			<p>三等奖：总积分第11-20名，奖品为精美天堂伞一把；</p>
			<p>纪念奖：总积分第21-30名，奖品为长城极致火力鼠标垫一个；</p>
		</div>
		<div class="footer">本次活动最终解释权属于中国长城计算机深圳股份有限公司。</div>
		<img class="bottom" src="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
images/bottom.png" alt="">
	</div>
	<!-- 积分 -->
	<div class="page rank" id="rank_page">
		<img src="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
images/jifen-title.png" alt="">
		<?php  $_smarty_tpl->tpl_vars['se'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['se']->_loop = false;
 $_from = $_smarty_tpl->tpl_vars['score']->value['data']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['se']->key => $_smarty_tpl->tpl_vars['se']->value) {
$_smarty_tpl->tpl_vars['se']->_loop = true;
?>
		<div class="rank-item">
			<span><?php echo $_smarty_tpl->tpl_vars['se']->value['num'];?>
</span>
			<span class="touxiang"><img <?php if ($_smarty_tpl->tpl_vars['se']->value['headimgurl']) {?>src="<?php echo $_smarty_tpl->tpl_vars['se']->value['headimgurl'];?>
"<?php } else { ?>src="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
images/boom.png"<?php }?> alt=""></span>
			<span class="name"><?php echo $_smarty_tpl->tpl_vars['se']->value['nickname'];?>
</span>
			<span class="fenshu"><?php echo $_smarty_tpl->tpl_vars['se']->value['allScore'];?>
分</span>
		</div>
		<?php } ?>
		<div class="footer">本次活动最终解释权属于中国长城计算机深圳股份有限公司。</div>
		<img class="bottom" src="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
images/bottom.png" alt="">
	</div>
	<!-- 分享好友 -->
	<div class="page share" id="share" onclick="shback()">
		<img src="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
images/share_pic.png">
	</div>
	<script type="text/javascript" src="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
js/jquery-1.11.2.min.js"></script>
	<script type="text/javascript">
		window.onload=MyAutoRun;
		var state = true;
		var type = "<?php echo $_smarty_tpl->tpl_vars['type']->value;?>
";
		// function statejudge( ){
		// 	if(state){
		// 		getid("musicpic").removeAttribute("class","music_pic");
		// 		getid("au_music").pause( );
		// 		state = false;
		// 	}
		// 	else{
		// 		getid("musicpic").setAttribute("class","music_pic");
		// 		getid("au_music").play( );
		// 		state = true;
		// 	}
		// }
		function getid(idname){
			return document.getElementById(idname);
		}
		function MyAutoRun( ){
			getid("aaa").setAttribute("class","load_block1");
			setTimeout(function(){
				getid("loading").style.display = "none";
				rank();
				if(type == 'rank')
				{
					show_jifen();	
				}
				if(type == 'start')
				{
					mybegin();
				}
			},800)
		}
		// function hide_index(){
		// 	getid("index_page").style.display = "none";
		// }
		// function hide_rank(){
		// 	getid("rank_page").style.display = "none";
		// 	score = 0;
		// 	speeds =1000;
		// 	speedX = 10;
		// 	speedY = 20;
		// 	game.state.start('preload');
		// }
		// function show_infor(){
		// 	getid("index_page").style.display = "none";
		// 	getid("info").style.display = "block";
		// }
		// function show_score(){
		// 	getid("info").style.display = "none";
		// 	game.state.start('over');
		// }
		// function pageshow(idname,obj){
		// 	return document.getElementById(idname).style.display = "block";
		// }
		function rank() {
			var str=window.location.search; 
			var wrapiii = '.' + str.substr(1,5);
			if (str=="?rank") {
				show_rule();
			}
			else {
				getid("index_page").style.display = "block";
			}
		}

		function show_rule(){
			getid("index_page").style.display = "none";
			getid("rule").style.display = "block";
			getid("back").style.display = "block";
		}
		function show_gift(){
			getid("index_page").style.display = "none";
			getid("gift").style.display = "block";
			getid("back").style.display = "block";
		}
		function show_jifen(){
			getid("index_page").style.display = "none";
			getid("rank_page").style.display = "block";
			getid("back").style.display = "block";
		}
		function mybegin(){
			window.location.href="index.php?g=mobile&m=index&a=game";
		}
		function myback(){
			getid("index_page").style.display = "block";
			getid("rule").style.display = "none";
			getid("gift").style.display = "none";
			getid("rank_page").style.display = "none";
			getid("back").style.display = "none";
		}
		function myshare(){
			getid("logo").style.display = "none";
			getid("index_page").style.display = "none";
			getid("share").style.display = "block";
		}
		function shback(){
			getid("share").style.display = "none";
			getid("index_page").style.display = "block";
		}
		
		$(function(){
			$('.gameTip').click(function(e){
				e.preventDefault();
				showToast($(this).attr('data-msg'));
			});
			
			$('.gameStart').click(function(e){
				e.preventDefault();
				mybegin();
			});
		});

	</script>
	<script>
		var jsdk = <?php echo $_smarty_tpl->tpl_vars['jsdk']->value;?>
;
		var share = <?php echo $_smarty_tpl->tpl_vars['shareInfo']->value;?>
;
		var is_share = <?php echo $_smarty_tpl->tpl_vars['config']->value['is_share'];?>
;
		var share_type = <?php echo $_smarty_tpl->tpl_vars['config']->value['share_type'];?>
;
	</script>
	<script src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
	<script type="text/javascript" src="<?php echo $_smarty_tpl->tpl_vars['_C']->value['hy_path'];?>
js/wx.js"></script>
</body>
</html><?php }} ?>
